﻿@model VisaApp.Helper.PagedData<VisaApp.Models.CauhoiModel>
@{ VisaApp.Helper.StringHelpers nameurl = new VisaApp.Helper.StringHelpers();}

<script type="text/javascript">
    $(document).ready(function () {
        $(".page-number").live("click", function () {
            show_Loading();
            var page = parseInt($(this).html());
            var ids = $("#selectProductPageTTHI").val();
            $.get("/News/GetCauHoiOncate?id=" + ids + "&page=" + page, function (data) {
                $(".FromListThongtinCanbietTTHI").html("");
                $(".FromListThongtinCanbietTTHI").html(data);
                $('#box-busy').fadeOut('medium', function () {
                    $('.black_overlay').css('display', 'none');
                });

            });
        });
    });

</script>

<div class="service-c2-ct">
    <h1>
        Câu hỏi thường gặp
    </h1>
    @if (Model.Data != null)
    {
     <ul class="sayingContent">   
        @foreach (var item in Model.Data)
        {
                
        <li class="note">
            <div id="@item.Id">
                <img src="/Content/images/customerIcon.png">
                <div class="text">
                    <p class="">
                        "@Html.Raw(item.Title)"
                    </p>
                    <div class="" style="padding-left:10px; padding-bottom:7px">
                        @Html.Raw(item.Noidung)
                    </div>
                    <span class="datepost">Gửi lúc: @string.Format("{0:HH:mm dd/MM/yyyy}", item.DateCreate)
                    </span>
                    <br>
                    <span class="nameKH">@item.Name - @item.Email </span><span style="float: right;">
                        <br>
                    </span>
                    <div clas="tl" class="answer">
                        <img src="/Content/images/visalogo.gif" class="avatar">
                        <div class="textAnswer">
                            <span class="traloi">Trả lời </span>
                            <div class="clr">
                            </div>
                            <p class="normal-font">
                                "@Html.Raw(item.Traloi)"</p>
                            <span class="Nguoitraloi">Bởi Visa </span>
                        </div>
                        <div class="clr">
                        </div>
                    </div>
                </div>
                <div class="clr">
                </div>
            </div>
        </li>
        }
        </ul>
    }
    <div class="clear"></div>
    <div class="PageNav">
        <span class="pageNavHeader">Trang @Model.CurrentPage / @Model.NumberOfPages</span>
        @for (int m = 1; m <= Model.NumberOfPages; m++)
        {
            if (m == Model.CurrentPage)
            {
            <a class="currentPage" href="javascript:void(0);">@m</a>
            }
            else
            {
            <a class="page-number" href="javascript:void(0);">@m</a>
            }
        }
        <a href="javsscript:void(0)" class="text">Sau &gt;</a>
    </div>
</div>
